def calculate_price(list_price: list) -> float:
    sum_1 = 0
    index = 0
    while True:
        price = list_price[index]
        if price < 1000:
            sum_1 = sum_1 + price
        else:
            sum_1 = sum_1 + (price - price*0.05)
            
        if len(list_price)-1 == index:
            break
        index += 1
    return sum_1


assert calculate_price([25,2000, 370.35]) == 2295.35
